package com.autumn.log;

import java.util.ArrayList;
import java.util.List;
import java.util.UUID;

import com.autumn.mq.event.EventDataConfigure;
import com.autumn.mq.event.IEventData;

/**
 * 日志事件数据
 * 
 * @author 老码农
 *         <p>
 *         Description
 *         </p>
 * @date 2018-01-12 00:11:00
 */
@EventDataConfigure(name = LogEventData.EVENT_NAME)
public class LogEventData implements IEventData {

	/**
	 * 
	 */
	private static final long serialVersionUID = 4194665338793014904L;

	/**
	 * 事件名称
	 */
	public final static String EVENT_NAME = "autumn.log.event.send";

	private String logId;
	private String serviceId;
	private String serviceAddress;

	private List<LogEventDataMessage> messages;

	/**
	 * 
	 */
	public LogEventData() {
		this.setLogId(UUID.randomUUID().toString().replace("-", ""));
		this.setMessages(new ArrayList<>());
	}

	public String getLogId() {
		return logId;
	}

	public void setLogId(String logId) {
		this.logId = logId;
	}

	public String getServiceId() {
		return serviceId;
	}

	public void setServiceId(String serviceId) {
		this.serviceId = serviceId;
	}

	public String getServiceAddress() {
		return serviceAddress;
	}

	public void setServiceAddress(String serviceAddress) {
		this.serviceAddress = serviceAddress;
	}

	public List<LogEventDataMessage> getMessages() {
		return messages;
	}

	public void setMessages(List<LogEventDataMessage> messages) {
		this.messages = messages;
	}

}
